const father = {
    name: 'Howard Stark',
    company: 'Stark Inc.'
}

Object.defineProperty(father, 'money', {
    enumerable: false,
    value: 100
})

const son = {
    name: 'Tony Stark'
}

Object.defineProperty(son, 'hero', {
    enumerable: false,
    value: 'IronMan'
});

son.__proto__ = father;

console.log('son.company:', son.company);
console.log('son.money:', son.money);
console.log('son.hero:', son.hero);
console.log('\nObject.getOwnPropertyNames(father):', Object.getOwnPropertyNames(father));
console.log('Object.getOwnPropertyNames(son):', Object.getOwnPropertyNames(son));

console.log('\nObject.keys(son):', Object.keys(son));

console.group('\nfor...in of son');
for (let k in son) { console.log(`son.${k}: ${son[k]}`) };
console.groupEnd();

console.log('\nmoney in son? ', ('money' in son));
